package com.google.code.timeeditapplication.model.implementation;

/**
 * A SearchResult contains the vital information from a TimeEdit search result,
 * ie its name and id.
 * 
 * @author deas
 * 
 */
public class SearchResult {
	private final String name, id;

	/**
	 * 
	 * @param name
	 *            The name of the search result
	 * @param id
	 *            The identificitaion number of the search result
	 */
	public SearchResult(final String name, final String id) {
		this.name = name;
		this.id = id;
	}

	/**
	 * 
	 * @return name of search result
	 */
	public String getName() {
		return this.name;
	}

	/**
	 * 
	 * @return identification number of search result
	 */
	public String getId() {
		return this.id;
	}

	/**
	 * @return name of search result
	 */
	@Override
	public String toString() {
		return getName();
	}
}
